import static org.junit.Assert.assertEquals;
import junit.framework.TestCase;

import org.junit.Test;

import GoldenEagle.Menu;
import GoldenEagle.Order;

public class TestOrder extends TestCase{

	Order order = new Order(1, 4, "Sam");

	Menu m = TestMenu.InitMenu();

	@Test
	public void testgetTable() {

		assertEquals(order.getTable(), 1);
	}

	@Test
	public void testgetNumOfCustomer() {
		assertEquals(order.getNumOfCustomer(), 4);
	}

	@Test
	public void testgetStaffName() {
		assertEquals(order.getStaffName(), "Sam");
	}

	@Test
	public void testtotlePrice() {
		
		//note that this loop count is limited by 2.
		for(int i = 0;i < 2;i++){
			order.add(m.getMenuSubject(i));
		}
		//Test price addition calculation
		assertTrue((int)order.totalPrice() == (int)116);
	}

}
